package com.ux.example
{
	import com.ux.control.VideoPlayer;
	import com.ux.manager.StageManager;
	
	import flash.display.Sprite;
	import flash.events.MouseEvent;
	
	[ SWF (width="600", height="600" ) ]
	public class VideoTest extends Sprite
	{
		private var av : VideoPlayer;
		private var isPlay : Boolean = false;
		private var _vol : Number = 0;
		
		public function VideoTest()
		{
			super();
			
			StageManager.stage = stage;
			
			av = new VideoPlayer( "../assets/hometheater0.flv" );
			addChild( av );
			
			av.addEventListener(MouseEvent.CLICK, onClick );

			av.playVideo();
			isPlay = true;
		}
		
		
		private function onClick( e:MouseEvent ):void 
		{
			_vol = _vol+0.1;
			trace( _vol );
			
			av.volume = _vol;
		}
	}
}